#ifndef CACHEREUPLOADINFO_H
#define CACHEREUPLOADINFO_H

#include <QObject>

class CacheReuploadInfo : public CacheBase
{
    Q_OBJECT
private:
    static constexpr const char* s_createTimeStampKey = "CreateTimeStamp";
    static constexpr const char* s_uploadTimesKey = "UploadTimes";
    static constexpr const char* s_idKey = "Id";
    static constexpr const char* s_infoKey = "Value1";
    static constexpr const char* s_stateKey = "Value2";
    static constexpr const char* s_reuploadInfoTableName = "Data3";
    static constexpr const char* s_reuploadTableCreateCmd = " \
                                            CREATE TABLE IF NOT EXISTS Data3\
                                            ( \
                                            Id INTEGER PRIMARY KEY   AUTOINCREMENT,\
                                            Value1 TEXT NOT NULL, \
                                            Value2 TEXT NOT NULL \
                                            )";
public:
    CacheReuploadInfo(QObject *parent = nullptr );
public:
    void createTable();
    void recvInfo(const QString &info);
    void getInfo(QList<qlonglong> &id,QList<QString> &info,QList<QString> status,const int32_t &num);
    void deleteInfo(QList<qlonglong> &id);
private:
    bool saveInfo(const QList<QString> &info);
};

#endif // CACHEREUPLOADINFO_H
